package com.dlc.shop.coupon.common.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.dlc.shop.coupon.common.model.CouponProd;
import org.apache.ibatis.annotations.Param;

import java.util.List;
/**
 * 优惠券商品信息
 * @author lanhai
 */
public interface CouponProdMapper extends BaseMapper<CouponProd> {

    /**
     * 删除优惠券关联
     * @param couponId 优惠券id
     */
    void deleteCouponProdsByCouponId(@Param("couponId") Long couponId);

    /**
     * 新增优惠券关联
     * @param couponId 优惠券id
     * @param prodIds 商品ids
     */
    void insertCouponProdsBatch(@Param("couponId") Long couponId, @Param("prodIds") List<Long> prodIds);
}
